#ifndef BILLS_H
#define BILLS_H

#include <iostream>

enum DENOMINATION {
    NONE = 0,
    ONE = 1,
    TWO = 2,
    FIVE = 5,
    TEN = 10,
    FIFTY = 50,
    HUNDRED = 100,
    FIVE_HUNDRED = 500,
    THOUSAND = 1000,
    FIVE_THOUSAND = 5000
};

class Bills {
private:
    DENOMINATION denom;
    unsigned int count;
public:
    // Constructors & destructor
    Bills();
    Bills(DENOMINATION denom, unsigned int count);
    Bills(const Bills &other);
    ~Bills();

    // Setters & getters
    void setDenomination(DENOMINATION new_denom);
    void setCount(unsigned int new_count);
    void setBill(DENOMINATION new_denom, unsigned int new_count);
    void setBill(std::pair<DENOMINATION, unsigned int> new_bill);

    DENOMINATION getDenomination();
    unsigned int getCount();
    std::pair<DENOMINATION, unsigned int> getBill();

    // Overloads
    Bills & operator=(const Bills &other);
    Bills & operator=(Bills &&other) noexcept;

    // Public methods (interface)
    unsigned int summa();

    // Friend functions
    friend std::ostream & operator<<(std::ostream &os, const Bills &bill);
    friend std::istream & operator>>(std::istream &is, Bills &bill);
};

std::ostream & operator<<(std::ostream &os, const Bills &bill);
std::istream & operator>>(std::istream &is, Bills &bill);

#endif // BILLS_H
